package de.java.shortys.utils.string;

public final class StringUtils {

	public static String firstToLowerCase(String target) {
		if ((target == null) || (target.length() == 0)) {
			return target;
		}
		return Character.toLowerCase(target.charAt(0)) + (target.length() > 1 ? target.substring(1) : "");
	}

	public static String firstToUpperCase(String target) {
		if ((target == null) || (target.length() == 0)) {
			return target;
		}
		return Character.toUpperCase(target.charAt(0)) + (target.length() > 1 ? target.substring(1) : "");
	}

	public static boolean isNullOrEmpty(String s) {
		if (s == null) {
			return true;
		}

		if (s.length() == 0) {
			return true;
		}

		return false;
	}

	private StringUtils() {
		// Empty
	}
}
